﻿
using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics;
using System.Globalization;
using System.Linq;
using System.Text;

namespace Jim.K3Cloud
{
    public class LocaleValue: List<KeyValuePair<int, string>>
    {
        public string GetName(int defaultLocal = 2052)
        {
            foreach (KeyValuePair<int, string> keyValue in this)
            {
                if(keyValue.Key== defaultLocal) return keyValue.Value;
            }
            return this.ToString();
        }

        public override string ToString()
        {
            if(this == null || this.Count == 0) return "";
            foreach (KeyValuePair<int, string> keyValue in this)
            {
                if(keyValue.Key== 2052) return keyValue.Value;
            }
            return "";

        }
    }
}